<div id="djdialog-{{ id }}" title="{{ title }}">
{{ text|safe }}
</div>

<script type="text/javascript">
$(function() {
    $('#djdialog-{{ id }}').dialog({
        'autoOpen': false,
        'width': {{ width }}
    });
    $('{{ opener_class }}').click(function() {
        $('#djdialog-{{ id }}').dialog('open');
        return false;
    });
});
</script>
